Release 10.1A: OpenEdge Development:
Web Services


Processing the schema and data for output TABLE-HANDLE parameters

This example shows how you might process the data from an output TABLE-HANDLE parameter by using the sample TABLE-HANDLE helper classes:

// Process the Output TABLE-HANDLE parameter 
ttHandle = ttHolder.value; 
MessageElement [] msgArrayOut = ttHandle.get_any( ); 
// msgArrayOut has one entry, the DataSet 
// Get the DOM representation of the MessageElement 
Element dataSetOut = msgArrayOut[0].getAsDOM( ); 
// Create a new RowSet Object based on the DataSet 
RowSet rsOut = new RowSet( ); 
/* 
Call the buildRowSet method on the RowSet object. 
buildRowSet creates a SchemaParser object to parse the <schema> element of the  
dataSetOut and creates the m_schema ColumnMetaData[ ] array representing the  
schema.  buildRowSet then parses the <Data> element and creates the m_rows 
Vector  
representing the data. 
*/ 
rsOut.buildRowSet(dataSetOut); 
// print out the data for the dynamic temp-table to the console 
rsOut.printData( ); 


Copyright © 2005 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095